<template>
  <div class="indextop">
    <div class="image">
      <img src="../assets/sta.png" alt="" />
    </div>
    <div class="search" @click="$router.push({ path: '/search' })">
      <span class="icon"></span>
      <h3>乾隆白菜</h3>
    </div>
    <div class="btn">
      <div class="btn1" @click="$router.push({ path: '/classify' })"></div>
      <div class="btn2"></div>
    </div>
  </div>
</template>

<script>
export default {};
</script>

<style lang="less" scoped>
.indextop {
  width: 100vw;
  padding: 10px 10px;
  display: flex;
  align-items: center;
  .image {
    width: 7vw;
    margin-right: 10px;
    img {
      vertical-align: middle;
    }
  }
  .search {
    flex: 1;
    width: 50vw;
    height: 9vw;
    background-color: #eee;
    border-radius: 3px;
    display: flex;
    align-items: center;
    padding-left: 10px;

    .icon {
      display: block;
      width: 15px;
      height: 15px;
      background-image: url("../assets/search.png");
      background-size: 100%;
      background-position: center;
    }
    h3 {
      font-size: 12px;
      color: #aaa;
      margin-left: 5px;
    }
  }
  .btn {
    // width: 20vw;
    // height: 10vw;
    display: flex;

    .btn1 {
      margin: 0 5px;
      margin-left: 10px;
      width: 6vw;
      height: 6vw;
      background-image: url("../assets/stl.png");
      background-size: 100%;
      background-position: center;
    }
    .btn2 {
      margin: 0 5px;
      width: 6vw;
      height: 6vw;
      background-image: url("../assets/stm.png");
      background-size: 100%;
      background-position: center;
    }
  }
}
</style>